Skip to content

explore(desktop): discovery-first onboarding landing (Discord-style) - #5976

Open
thomaspblock wants to merge 1 commit into
mainfrom
explore/discord-style-landing
Open

explore(desktop): discovery-first onboarding landing (Discord-style)#5976
thomaspblock wants to merge 1 commit into
mainfrom
explore/discord-style-landing

Conversation

@thomaspblock

Copy link
Copy Markdown
Contributor

Summary

Exploration: discovery-first onboarding (Discord-style). On first open, the app lands on a community discovery screen instead of the agent-setup corridor.

  • New discover page prepended to MachineOnboardingPage — now the initial page (identity-lost still routes to key import; initialPage overrides preserved).
  • DiscoveryLanding.tsx: featured community cards with one-click Join, plus "advanced setup" (old corridor) and "use an existing key" (key import) escape hatches.
  • One-click join defers all agent setup: identity is persisted silently via getIdentity(), machine onboarding completes, and a first-community community-onboarding transaction connects to the chosen relay. Backup / harness / config become post-join concerns.
  • featuredCommunities.ts: static featured-community list (incl. Buzz HQ) — a relay-served directory is a natural follow-up.
  • Identity page gains a Back button returning to discover.
  • Fix: OnboardingFooter renders the footer slot before the Back button so Back stays clickable above wide docked CTA groups (found via the e2e spec — the identity help trigger's pointer-events-auto group intercepted clicks).
  • e2e screenshot spec discovery-landing-shot.spec.ts added to the smoke project.

Verification

  • tsc clean, biome + repo checks ALL_GREEN
  • Full unit suite: 4954/4954 pass
  • e2e spec passes; screenshots posted in a comment below (camo blocks relay media URLs)

Links

  • Track 2 issue: buzz://issue?id=4215da4b35ff9576b97b101e03f5b50140e38a396793f0517b4f8c27d6f43e68&owner=011987e296fd5006292d2f930b574be47c7801048d1983c46c425d3c95f0cffd (Onboarding project)
  • Originating thread: buzz://message?channel=661c64d4-4a78-4562-87ac-452cbf89a0c4&id=d909d4087cf780e3159bd727005909cc41a2cac22f3c9bd3d6a8f42b8130c606

First open now lands on a community discovery screen instead of the
agent-setup corridor. Featured communities are joinable in one click:
identity is persisted silently and a first-community onboarding
transaction connects to the chosen relay, deferring backup, harness,
and agent config to post-join. The old corridor remains reachable via
'advanced setup', and key import via 'use an existing key'.

Also fixes OnboardingFooter stacking so the Back button stays
clickable above wide docked CTA groups.

Exploration for the community-first onboarding flip (Track 2).

Co-authored-by: Thomas Petersen <thomasp@squareup.com>
Signed-off-by: Thomas Petersen <thomasp@squareup.com>
@thomaspblock
thomaspblock requested a review from a team as a code owner August 15, 2026 18:02
@thomaspblock

Copy link
Copy Markdown
Contributor Author

Screenshots

pr-5976--01-discovery-landing

pr-5976--02-advanced-setup-corridor

pr-5976--03-after-join-click

@themiguelamador themiguelamador left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two blockers remain in the discovery-first join path:

  • communityOnboarding.start() deliberately returns false when a different onboarding transaction is already pending. quickJoinCommunity ignores that result and still calls complete(identity.pubkey). An acknowledged deep-link transaction therefore lets the user click a featured card, completes machine onboarding, and then connects the other pending community instead of the one shown.
  • Three cards are marked openJoin: true even though their relay hosts do not resolve (agents.buzz.builderlab.xyz, nostr.buzz.builderlab.xyz, and nomads.buzz.builderlab.xyz). DiscoveryLanding never consults openJoin, so all three dead endpoints are advertised as working one-click joins.

I fixed both in Complear:review/pr-5976-fix at 01bc5be66f5b4ed54380c7655aa7794bc8f779b7: rejected transaction starts now leave machine onboarding incomplete and show an actionable error; unavailable entries render disabled “Coming soon” buttons; and the E2E spec covers both the disabled catalog entries and the pending-transaction collision.

Verification:

  • fresh pnpm build:e2e — passed
  • focused discovery Playwright suite — 2 passed
  • screenshot SHA-256 check — all 3 states distinct
  • focused Biome — clean
  • pnpm exec tsc --noEmit — passed
  • pnpm test — 4,954 passed

@jedwards27 jedwards27 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:bot: Jude’s code review agent — requesting changes at exact head 3ddaa0d59d6192cf49877bfeb7d5d94702d90101 (base 78cbffeb64c01220e705adf0aa9690fdbd0d7a37).

1. High — three of four first-run choices are fictional, actionable communities

desktop/src/features/onboarding/featuredCommunities.ts:25-60 marks all four entries openJoin: true and supplies exact member counts, while desktop/src/features/onboarding/ui/DiscoveryLanding.tsx:51-92 renders every entry with an enabled Join action and never consults openJoin. At review time, only buzz.block.builderlab.xyz resolved; agents.buzz.builderlab.xyz, nostr.buzz.builderlab.xyz, and nomads.buzz.builderlab.xyz had no A record and curl failed with Could not resolve host.

That makes three primary first-run actions guaranteed dead ends after Buzz has silently created an identity and completed machine onboarding. The invented membership counts also present nonexistent groups as established social proof. Do not ship placeholder directory entries as actionable production data. Limit the compiled catalog to verified open relays, or visibly disable/segregate fixtures; source availability and counts from a trusted directory before presenting them as live facts.

Reproduction:

for h in buzz.block.builderlab.xyz agents.buzz.builderlab.xyz nostr.buzz.builderlab.xyz nomads.buzz.builderlab.xyz; do
  dig +short "$h" A
  curl -sS --connect-timeout 5 --max-time 10 -o /dev/null \
    -w '%{http_code} %{errormsg}\n' "https://$h/"
done

2. High — a rejected join transaction still completes machine onboarding

desktop/src/features/onboarding/ui/MachineOnboardingFlow.tsx:168-180 ignores the boolean returned by communityOnboarding.start(...) and always calls complete(identity.pubkey). But desktop/src/features/onboarding/communityOnboarding.tsx:340-350 intentionally returns false when an existing transaction targets a different relay. With an acknowledged pending deep-link transaction, choosing Buzz HQ therefore completes machine onboarding while preserving and connecting the older community; the card the user selected is silently discarded.

Treat false as a failed start: do not complete machine onboarding, and surface an actionable choice to resume or replace the existing transaction. Add a permanent collision test proving the selected relay wins or the user remains in onboarding with clear feedback.

3. High — the changed first-render contract leaves exact-head Desktop CI red

The new landing replaces recovery controls on first render, but the existing onboarding suite still drives those controls directly. Six tests time out at desktop/tests/e2e/onboarding.spec.ts:708,799,822,846,870,924; exact-head checks fail in Desktop E2E Integration (1/2), smoke shards 2/3, and both aggregate Desktop jobs. This is directly coupled to the PR's first-screen change, not an unclassified infrastructure failure. Update the affected workflows to enter recovery through the new landing and keep their original recovery assertions intact.

Evidence:

gh pr checks 5976 --repo block/buzz
gh run view 31900028469 --repo block/buzz --log-failed

4. Moderate — every community action has the same accessible name

desktop/src/features/onboarding/ui/DiscoveryLanding.tsx:80-89 exposes four buttons named only Join; the community name is not programmatically associated with each button. A screen-reader button list cannot distinguish the choices. This misses the repository's WCAG 2.1 AA floor (VISION.md:196-207). Give each action a community-specific accessible name, for example Join Buzz HQ, and assert those names by role.

Validation and required regression shape

At this exact head, independent runs passed pnpm typecheck, pnpm check, pnpm build:e2e, all 4,954 Desktop unit tests in one run, and the authored discovery Playwright spec. One separate full-unit run had a single long-running terminalBannerWave.test.mjs worker failure after 4,934 passes; that target then passed 20/20 alone, so I am not attributing it to this PR without a main comparison.

The new desktop/tests/e2e/discovery-landing-shot.spec.ts proves visual rendering, the advanced/back route, and one mocked Buzz HQ happy path. It does not discriminate the rejected-transaction collision, dead/unavailable entries, community-specific accessible names, real relay selection, or connection failure recovery. Please add those risk-shaped cases and provide exact-artifact evidence for at least one real endpoint join plus one truthful failure/recovery path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants